class Lecture
  attr_accessor :department, :code, :title, :credit1, :credit2, :lecturer, :time, :room, :capacity
  def initialize(department, code, title, credit1, credit2, lecturer, time, room, capacity)
    @department = department
    @code = code
    @title = title
    @credit1 = credit1
    @credit2 = credit2
    @lecturer = lecturer
    @time = time
    @room = room
    @capacity = capacity
  end
  
  def to_s
    [ @department, @code, @title, @credit1, @credit2, @lecturer, @time, @room, @capacity] * ',' 
  end
end